package com.moli.iov.alarm.model.dto.res;

import com.moli.iov.alarm.enums.IsAlarmingEnum;
import java.io.Serializable;
import lombok.Data;

/**
 * <p>
 * 报警状态
 * </p>
 *
 * @author zql
 * @since 2020/2/27 11:09
 */
@Data
public class AlarmDetailDto implements Serializable {

  private static final long serialVersionUID = 4497360850988630864L;

  /**
   * 失联报警  1 正在报警；0未报警
   */
  private int isOffLine;

  /**
   * 车载终端报警 1 正在报警；0未报警
   */
  private int isTerminal;

  /**
   * 围栏报警  1 正在报警; 0未报警
   */
  private int isFence;

  /**
   * 里程异变报警 1 正在报警；0未报警
   */
  private int isMileExcep;

  public static AlarmDetailDto newInstance(){
    AlarmDetailDto alarmDetailDto = new AlarmDetailDto();
    alarmDetailDto.setIsOffLine(IsAlarmingEnum.NO.getFlag());
    alarmDetailDto.setIsTerminal(IsAlarmingEnum.NO.getFlag());
    alarmDetailDto.setIsFence(IsAlarmingEnum.NO.getFlag());
    alarmDetailDto.setIsMileExcep(IsAlarmingEnum.NO.getFlag());
    return alarmDetailDto;
  }
}
